package com.mor.shiro.test;


import java.util.*;
/**
 * @author zht
 * @version 1.0
 * @createDate 2020/08/15 16:03
 */

public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int t = scanner.nextInt();
        while (t-- > 0) {
            int a = scanner.nextInt();
            int b = scanner.nextInt();
            int k = scanner.nextInt();
            int v = scanner.nextInt();
            int total = 0,res=0;
            int [][] db=new int[a+1][k+1];
            // 箱子的个数res和每个箱子用几个隔板是固定的
            // 一个隔间能存放的物品数量v是固定的,隔板数b是固定的
            for (int i = 1; i <=db.length ; i++) {
                for (int j = 0; j <=db[0].length ; j++) {

                }
            }
        }
        scanner.close();
    }
}
